﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Class_Entity;
using BussinessObject;
using System.Data;
using System.Data.SqlClient;

public partial class WebApplication_AccountDetails : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["RoleCode"] != null)
        {
            if (!Page.IsPostBack)
            {
                loadData();
            }
        }
        else
            Response.Redirect("Login.aspx");
    }
    private void loadData()
    {
        Label1.Text = Session["Username"].ToString(); 

        Users us = new Users();
        BOUsers bus = new BOUsers();

        us.Username = Session["Username"].ToString();

        DataSet ds = new DataSet();
        ds = bus.Load_UserDetail(us);
        DetailsView1.DataSource = ds;
        DetailsView1.DataBind();

    }
    protected void Button1_Click(object sender, EventArgs e)
    {

        Response.Redirect("EditAccountDetails.aspx");
    }
}